package com.easyban.entity.enums;

public enum FileCodeEunm {
    DEL(0,"删除"),
    RECYCLE(1,"回收站"),
    USING(2,"使用中");

    FileCodeEunm(Integer flag, String desc) {
        this.flag = flag;
        this.desc = desc;
    }

    private Integer flag;
    private String desc;

    public Integer getFlag() {
        return flag;
    }

    public void setFlag(Integer flag) {
        this.flag = flag;
    }

    public String getDesc() {
        return desc;
    }

    public void setDesc(String desc) {
        this.desc = desc;
    }
    public static FileCodeEunm getByflag(Integer flag){
        for (FileCodeEunm codeEunm : FileCodeEunm.values()) {
            if (flag.equals(codeEunm.getFlag())){
                return codeEunm;
            }
        }
        return null;
    }

}
